1. Field of the Invention
This invention is related to digital systems and, more particularly, to caches within digital systems.
2. Description of the Related Art
Processors and/or the computer systems including the processors typically provide caches to alleviate the high memory latency frequently experienced in computer systems. Generally, a cache is a relatively small, high speed memory which may store copies of data corresponding to various recently-accessed memory locations. Generally, cache storage is allocated and deallocated in units of cache lines (a group of bytes from contiguous memory locations). In other words, the cache may include multiple entries, and each entry may include storage for a cache line of bytes. If requested data for an access is not in the cache (a “miss”), an entry is allocated for the cache line including the requested data and the cache line is filled into the allocated entry. Subsequently, the data may be found in the cache upon request (a “hit”). In some cases, a portion of the cache line (often called a “sector”) may be valid while other portions are invalid. However, the entire cache entry is allocated for the cache line if one or more of the sectors are valid.
It is generally necessary to test the memory (including cache memory) of an integrated circuit or system (e.g. after manufacture and prior to shipping to a customer) to ensure that the memory has no defects. Defects may occur due to contamination in the fabrication of the memory circuit, a problem with the masks used during the fabrication, or other manufacturing errors.
Typically, the testing of memories has been performed by including hardware embedded in the memory or situated close to the memory to perform the testing. This hardware is typically referred to as built-in self test (BIST) hardware. Since the BIST hardware is used only for testing purposes, the BIST hardware must be as small (in terms of circuit area, e.g. numbers of transistors) as possible to minimize the cost of the BIST hardware. Thus, the testing strategies that may be applied by BIST hardware have generally been limited to those strategies that can be implemented using a minimal amount of hardware. Furthermore, if the BIST hardware itself is implemented incorrectly, false failures or incomplete test coverage may result. A more flexible method for testing a memory is therefore desired.